Model
is a combination of data (which can include configuration, trained model weights, or other information) and code that defines how the model operates. By structuring your code to be compatible with this API, you benefit from a structured way to version your application so you can more systematically keep track of your experiments.
To create a model in Weave, you need the following:You can call the model as usual with:This will track the model settings along with the inputs and outputs anytime you call After calling this, you will see that you now have two versions of this Model in the UI, each with different tracked calls.For additional instructions, see serve.
- a class that inherits from
weave.Model
- type definitions on all parameters
- a typed
predict
function with@weave.op()
decorator
predict
.